<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<form class="form-horizontal form-label-left" action="appinfoaddsave" method="post" enctype="multipart/form-data">
    论文题目：<input type="text" id="title"><br/>
    类型：<<select name="type" id="type">

    </select>><br/>
    论文摘要 <input type="text" name="zy">
    论文文件：<input type="file" name="file"><br/>
    <input type="button" id="add" value="保存">
    <input type="button" value="返回">
</form>
</body>
<script src="http://libs.baidu.com/jquery/2.1.4/jquery.min.js"></script>
<script type="text/javascript">
    $("#add").click(function() {
        var formData = new FormData($('#uploadForm')[0]);
        $.ajax({
            type : 'post',
            url : '/papermanage/tpaper/positionUpload',
            data : formData,
            cache : false,
            processData : false,
            contentType : false,

        }).success(function(data) {
            if(data.indexOf("true")>-1){
                alert("上传成功");
            }else{
                alert("上传失败");
            }
        }).error(function() {
            alert("上传失败!!!");

        });
    });
</script>
</html>